//
// Mixins
// --------------------------------------------------

// Border Radius
.border-radius(@radius) {
  -moz-border-radius: @radius; /* Firefox */
  -webkit-border-radius: @radius; /* Safari, Chrome */
  -khtml-border-radius: @radius; /* KHTML */
  border-radius: @radius; /* CSS3 */
}
// Placeholder text
.placeholder(@color: @input-color-placeholder) {
  &:-moz-placeholder            { color: @color; } // Firefox 4-18
  &::-moz-placeholder           { color: @color; } // Firefox 19+
  &:-ms-input-placeholder       { color: @color; } // Internet Explorer 10+
  &::-webkit-input-placeholder  { color: @color; } // Safari and Chrome
}

// Text overflow
// Requires inline-block or block for proper styling
.text-overflow() {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

// Box-sizing
.box-sizing(@border-box) {
	box-sizing: @border-box;
	-moz-box-sizing: @border-box;
}

// Drop shadows
.box-shadow(@shadow) {
  -webkit-box-shadow: @shadow; // iOS <4.3 & Android <4.1
          box-shadow: @shadow;
}

// User select
// For selecting text on the page
.user-select(@select) {
  -webkit-user-select: @select;
     -moz-user-select: @select;
      -ms-user-select: @select;
       -o-user-select: @select;
          user-select: @select;
}

// CSS3 Content Columns
.content-columns(@column-count; @column-gap: @grid-gutter-width) {
  -webkit-column-count: @column-count;
     -moz-column-count: @column-count;
          column-count: @column-count;
  -webkit-column-gap: @column-gap;
     -moz-column-gap: @column-gap;
          column-gap: @column-gap;
}

// Opacity
.opacity(@opacity) {
	opacity: @opacity;
	-moz-opacity: @opacity; 
	-khtml-opacity: @opacity;	
	@opacity-ie: (@opacity * 100);
	filter: ~"alpha(opacity=@{opacity-ie})";
	zoom: 1;
}

// Button pseudo states
// -------------------------
// Easily pump out default styles, as well as :hover, :focus, :active,
// and disabled options for all buttons
.btn-pseudo-states(@color; @background; @border) {
  color: @color;
  background-color: @background;
  border-color: @border;

  &:hover,
  &:focus,
  &:active,
  &.active {
    background-color: darken(@background, 5%);
        border-color: darken(@border, 10%);
  }

  &.disabled,
  &[disabled],
  fieldset[disabled] & {
    &,
    &:hover,
    &:focus,
    &:active,
    &.active {
      background-color: @background;
          border-color: @border
    }
  }
}
